Application programs supporting language translation must be able to transform a text readable from left to right in English, for instance, into a text readable from right to left in Arabic, Hindi, or Hebrew. Existing application program supporting bi-directional languages do this in an automatic way: the program is able to receive inputs from the user and to show output according to the direction of the language. In graphical user interfaces, not only text but also layouts and images must be transformed from right-to-left to left-to-right and the opposite, from right-to-left to left-to-right.
In graphical user interface applications supporting bi-directional languages today, the text and layout are displayed automatically in the desired direction on the basis of a unique resource bundle containing translated text. A resource bundle is the portion of a piece of software that holds application data, but not user data, separate from the program itself. Typical resources include icons, window positions, dialog box definitions, program text, and menus. The application makes a transformation on the text and layout elements from this bundle according to the language used.
However, prior art methods to internationalize GUIs do not provide an automatic solution for images today. A typical solution is described in Chapter 9 of the book “Java Internationalization” by Andy Deitsch and David Czarnecki, edited by O'Reilly in March 2001. Their solution is to provide different images in the resource bundle, one for each locale supported by the application. A locale is a set of user preference information related to the user's linguistic, environmental, and cultural conventions. Furthermore, the code of the application must include logic to load the right image according to the language used. The drawback of this unautomated solution is doubling of program storage and library for image space and higher code complexity.
One particular difficulty with image mirroring is the fact that depending on the meaning of an image, it may need to be mirrored, or not. For instance, the image of a joystick may need to be reversed if the direction of the language changes, whereas a road label with ‘STOP’ inside has no need to be mirrored. A solution is proposed in the ‘Mirroring Awarness’ document posted as web pages on January 2003 on the Microsoft (Microsoft is a trademark of Microsoft Corporation in certain countries) web site at the http://www address: microsoft.com/globaldev/getwr/steps/WRG_mirror.mspx.
The method proposed here for a developer of a pure Windows (Windows is a trademark of Microsoft Corporation in certain countries) application is to mirror the application automatically. Every graphical object will be mirrored, images and icons included. In this case, a problem arises in that some images, as mentioned above, should not be mirrored, depending on their meanings. The Microsoft pages suggest adding extra logic within the code to disable the automatic mirroring temporarily in such cases. This is performed by calling some specific disabling mirroring Windows instructions. Conversely, the developer can disable or not enable the automatic mirroring. In this case no image will be automatically mirrored, and some explicit instructions in the code are needed to enable the mirroring. In Web applications, the Microsoft document suggests setting a flag equal to RTL (Right To Left). Nevertheless, in this case the images will not be mirrored automatically, as the developer has to apply the transformation explicitly by calling a cascading style sheet filter (script language like) that will transform the image. This mirroring solution is not automatic as the application code or Web pages have to be modified to introduce a logic for enabling or not enabling mirroring.
Consequently, there is a need for a way to mirror images in application programs which does not requiring logic in the application code itself to enable or disable.